package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.CaseVaccinationMapper;
import com.ruoyi.system.domain.CaseVaccination;
import com.ruoyi.system.service.ICaseVaccinationService;
import com.ruoyi.common.core.text.Convert;

/**
 * 病例接种疫苗情况Service业务层处理
 * 
 * @author ruoyi
 * @date 2022-04-03
 */
@Service
public class CaseVaccinationServiceImpl implements ICaseVaccinationService 
{
    @Autowired
    private CaseVaccinationMapper caseVaccinationMapper;

    /**
     * 查询病例接种疫苗情况
     * 
     * @param id 病例接种疫苗情况主键
     * @return 病例接种疫苗情况
     */
    @Override
    public CaseVaccination selectCaseVaccinationById(Long id)
    {
        return caseVaccinationMapper.selectCaseVaccinationById(id);
    }

    /**
     * 查询病例接种疫苗情况列表
     * 
     * @param caseVaccination 病例接种疫苗情况
     * @return 病例接种疫苗情况
     */
    @Override
    public List<CaseVaccination> selectCaseVaccinationList(CaseVaccination caseVaccination)
    {
        return caseVaccinationMapper.selectCaseVaccinationList(caseVaccination);
    }

    /**
     * 新增病例接种疫苗情况
     * 
     * @param caseVaccination 病例接种疫苗情况
     * @return 结果
     */
    @Override
    public int insertCaseVaccination(CaseVaccination caseVaccination)
    {
        return caseVaccinationMapper.insertCaseVaccination(caseVaccination);
    }

    /**
     * 修改病例接种疫苗情况
     * 
     * @param caseVaccination 病例接种疫苗情况
     * @return 结果
     */
    @Override
    public int updateCaseVaccination(CaseVaccination caseVaccination)
    {
        return caseVaccinationMapper.updateCaseVaccination(caseVaccination);
    }

    /**
     * 批量删除病例接种疫苗情况
     * 
     * @param ids 需要删除的病例接种疫苗情况主键
     * @return 结果
     */
    @Override
    public int deleteCaseVaccinationByIds(String ids)
    {
        return caseVaccinationMapper.deleteCaseVaccinationByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除病例接种疫苗情况信息
     * 
     * @param id 病例接种疫苗情况主键
     * @return 结果
     */
    @Override
    public int deleteCaseVaccinationById(Long id)
    {
        return caseVaccinationMapper.deleteCaseVaccinationById(id);
    }
}
